test/unit-tests#67
Open
DYung26 wants to merge 72 commits into
Open
Conversation
…LLM` querying with strategy-based execution, parallel model handling, multimodal message building, and weighted model scoring
…coding functions for `matplotlib` integration
…, performance, and fallback options
…on with key validation and model listing
…` models with endpoint, key validation, and model listing
… list_models, and validate_key methods
…orting text and multimodal queries with validation
… validation and supported models listing
…point with query, list_models, and key validation
…Ollama` models with query and validation
…th query, list_models, and key validation
…PI` with query, list_models, and key validation
…providers, manage `API` keys, and handle queries
…odels with iteration-based escalation
…order until success, with optional success tracking
…ghest-performance models with fallback to lower tiers
…l models for balanced usage
… provider/model pairs with iteration-aware selection
…ace` and `ProviderManager` with strategy-based model selection, remove `Groq`-specific hardcoding, and unify image handling
…ine to comply with `PEP8` formatting
…add new `AI/LLM` packages; update `setup.py` to read `README` safely and include additional dependencies
… license, and examples to `v0.1.3`
…arams (strategy, models, iterations, interactivity, timeout)
…d plot generation and validation system
…otlib plot mappings for common chart types
…te and grouped categorical plots
…ouped data handling
…riable visualization
…ation, validation, and retrieval
… switch to registry-based unified plotgen `API` using `Basic/Smart` generators
…filing and variable-type detection
…egation and recommendation refinement
…t generation based on dataframe schema
… into structured visualization recommendations
…ting model querying, parsing, and ensemble scoring
… for external access
…gic to dedicated `recommender` module - Removed the inlined `VisualizationRecommender` class from `suggestions.py` and imported it from `visual_suggestion.recommender` - Simplified `suggestions.py` to serve as a lightweight interface for visualization recommendation - Updated `__init__.py` imports to correctly expose `VisualizationRecommender` from its new package - Enhanced `recommender()` function to support: - `StrategyName` parameter for configurable model selection strategy - `selected_models`, `interactive`, and `timeout` arguments for flexible runtime behavior - Improved module clarity and reduced redundancy by centralizing model, API, and ensemble logic under the recommender system
…eration with inline image streaming
… synthesis with streaming support
…tgen extensions, and message orchestration
…ining chat, audio, file, and realtime clients
…tool OpenAI function calling (plotgen, explainer, recommender)
…t` assistant with user instruction injection
…me session keys via `OpenAI API`
…ents for chat and audio responses
…nd `SmartPlotGenerator`, replacing deprecated `PlotGenerator`
… `PlotExplainer` and explainer `API` coverage
…icPlotGenerator`, `SmartPlotGenerator`, and `plotgen` integration tests
…`VisualizationRecommender` initialization, parsing, and `LLM` integration
…est_suggestions` into `test/unit` for clearer test structure organization
…ner` run with `Groq` and `OpenAI` models
…nd custom plot generation examples
…g with multiple `LLM` providers
…recommender` modules with consistent `API` handling and helper usage - Added default argument values to `VisualizationRecommender` and `PlotExplainer` constructors for strategy, models, timeout, and interactivity - Introduced `self.api_keys` and standardized `ProviderManager` initialization across both components - Updated `test_explanations` to use shared helper functions `encode_image` and `save_plot_to_image` from `core.utils` - Revised `test_plotgen` to align with new `_default_plots` naming and initialization logic - Refactored `test_suggestions` to leverage new `ResponseParser`, updated recommendation pipeline, and aligned prompt/query flow - Commented deprecated internal tests tied to removed private methods (`_get_all_recommendations`, `_parse_recommendations`, etc.) - Ensured test assertions verify model availability and provider correctness under new recommender structure
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces major enhancements to the PlotSense package, focusing on expanding AI model provider support, updating dependencies, and improving documentation and usability. The most important changes are the addition of new LLM provider integrations (Groq, Gemini, Anthropic, Azure OpenAI), updates to package metadata and dependencies, and improvements to usage examples and documentation. These changes make PlotSense more flexible and robust for AI-powered data visualization.
AI Model Provider Integrations
Added new provider classes for Groq (
plotsense/core/providers/groq.py), Gemini (plotsense/core/providers/gemini.py), Anthropic (plotsense/core/providers/anthropic.py), and Azure OpenAI (plotsense/core/providers/azure_openai.py), each with methods for querying, listing models, and validating API keys. All providers inherit from a new abstract base class (plotsense/core/providers/base.py). [1] [2] [3] [4] [5]Introduced a new strategy enumeration for model selection (
plotsense/core/enums/strategy.py).Dependency and Metadata Updates
Updated required dependencies to include
groq,anthropic,openai,google-genai,python-dotenv, andrequests, and raised the minimummatplotlibversion to 3.8.0. Package metadata now reflects new authors, license change to Apache 2.0, and improved project URLs. [1] [2] [3]Added new source files and expanded package structure to support new features and tests. [1] [2] [3]
Documentation and Usage Improvements
PKG-INFOto reflect new features, usage patterns, supported plots, and workflow examples. Improved code examples for plot generation and explanation, clarified API authentication, and added a feedback form link. [1] [2] [3] [4] [5]API Changes and Refactoring
BasicPlotGenerator,SmartPlotGenerator) inplotsense/__init__.py.License and Contributor Updates
These changes collectively make PlotSense more extensible, easier to use, and ready for advanced AI-powered data visualization workflows.